<!DOCTYPE HTML>
<html>
	<head>
		<title>Topranking.cn-中国自媒体排行榜</title>

		<link rel="stylesheet" type="text/css" href="/skin/css/reset.css" />
		<link rel="stylesheet" type="text/css" href="/skin/css/layout.css" />
		<link rel="stylesheet" type="text/css" href="/skin/css/fina.css" />
		<link rel="stylesheet" type="text/css" href="/skin/css/feature.css" />
		<script src="/skin/js/jquery-2.0.3.min.js"></script>
		<!--script src="/skin/js/tools.js"></script-->
		<!--script src="/skin/js/ui.js"></script-->
		<script src="/skin/js/reui.js"></script>


	</head>
	<body>
		

<style>
body{overflow: hidden;background: url(/passport/img/bg.png) no-repeat center center;}
.login-form{font-size:16px;}

.tips{color:red;display:inline-block;margin-left:10px;}
.n-form{background-color: #f9f9f9;color:#fff;}
.n-form dt{width:100px;}
.n-form dd{margin-left:110px;}
.n-form dd input{margin:0px;border:none;}
.n-form dd input:focus{background-color:#FFE191;}
.n-form dd img{margin-left:2px;}
</style>
<div class="n-middle n-max-width">
	<div class="login-form">

		<form method="post" action="" onsubmit="return false;">
		<dl class="n-form" style="width:440px;padding:40px 0px;margin:50px auto;background:url(/passport/img/passport-box.png);border-radius: 20px;">
			<h3 style="text-align:center;margin-bottom:50px;font-size:30px;">中自榜 | 登录</h3>
			<dt>用户名：</dt>
			<dd>
				<div style="border-radius: 5px;border:1px solid #868789;background-color:#fff;width:220px;padding:2px;">
					<img src="/passport/img/uname.png" />
					<input id="uname" name="uname" type="text" tips="管理员" value="">
				</div>
				</dd>
			<dt>密　码：</dt>
			<dd>
				<div style="border-radius: 5px;border:1px solid #868789;background-color:#fff;width:220px;padding:2px;">
					<img src="/passport/img/password.png" />
					<input id="password" name="password" type="password" />
				</div>
				</dd>
			<dt>验证码：</dt>
			<dd>
				<div style="border-radius: 5px;border:1px solid #868789;background-color:#fff;width:100px;padding:2px;display:inline-block;">
					
					<input id="vcode" name="vcode" type="text" style="width:70px;margin:0;" />
				</div>
				<img style="cursor: pointer;height:34px;" onclick="$(this).attr('src','/common/vcode.html?t='+Math.random())" src="<?=n_url('common','vcode')?>" />
			</dd>
			<dt>&nbsp;</dt>
			<dd>
				
				<button style="border-radius: 5px;" onclick="return dologin()" onfocus="this.blur()" alt="登 录" >登录</button>
				<div class="tips">&nbsp;</div>
			</dd>
			<div style="text-align: center;">
				还没有账号，我要
				 [<?=n_href(n_url('passport','reg'),'注册','style="color:#E4BB83;"')?>]
				，返回[<?=n_href(n_url('index','index'),'首页','style="color:#E4BB83;"')?>]
			</div>

		</dl>
		</form>
		
	</div>
</div>

<script>
	function dologin(){
		var vcode = $("#vcode").val()?$("#vcode").val():'';
		$.getJSON('/passport/dologin.html',{'uname':$("#uname").val(),'password':$("#password").val(),'vcode':vcode},function(cb){
			$(".tips").html(cb.msg);
			setTimeout(function(){
				if(cb.state){
					//alert(cb.referer);
					//location.href = !!cb.referer?cb.referer:"<?=(defined('N_USER') && N_USER=='Y')?'/user/index.html':'/index/manage.html'?>";
					location.href = '<?=$data["referer"]?>';
				}else if('Y'==cb.vcode){
					if(0==$('#vcode').length){
						location.reload();
					}else{
						$('#vcode').next('img').attr('src','/common/vcode.html?r'+new Date().getTime());
					}
				}
			},1000);
		});
	}
</script>




	</body>
</html>